<script>
import Editor from '@tinymce/tinymce-vue'

export default {
    data() {
        return {
            htmlStr: ''
        }
    },
    mounted() {

    },
    methods: {
        change(event) {
            // console.log(event.level.content);
            this.htmlStr = event.level.content
        }
    },
    components: {
        Editor
    }
}
</script>
<template>
    <div>
        <Editor @change="change" api-key="ti5z5gbrvf9yq2y5pimcg5h12xscyyehiys6vyxk9y0rqw35" :init="{
            language: 'zh_CN',
            plugins: 'image link lists media'
        }" />

        <div v-html="htmlStr"></div>

    </div>
</template>
